<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
	<title>listusers</title>
  <link rel="stylesheet" href="./assets/css/bootstrap.min.css">
  <style>
  body{background-image:url(./poster/2.jpg);background-repeat:no-repeat;background-size:cover;}
  table, td, th
{
  border:1px solid green;
}
th
{
  background-color:green;
  color:white;
}
h2 {font-weight:bold;}
  </style>
</head>
<body>
<h6><a href="admin.php?c=user&m=menu">返回menu </a><h6>
<center><h2>动漫用户列表(共有<?php  echo count($data['user']);?> 名用户)</h2></center>
<div class="col-md-8=12">
<table class="table table-hover"> 
	<tr>
		<th>用户编号</th>
		<th>用户名</th>
		<th>性别</th>
		<th>生日</th>
		<th>爱好</th>
		<th>学历</th>
		<th>头像</th>
		<th>操作</th>
	</tr>
	<?php 
       foreach ($data['user'] as $row ) {
      ?>

      <tr>
      	<td><?php echo $row['uid'];?></td>
      	<td><?php echo $row['uname'];?></td>
      	<td><?php    if($row['gender']==0)
                       echo "男";
                       else
                         echo "女";


        ?></td>

      	<td><?php echo $row['birthdate'];?></td>
      	<td><?php echo $row['hobby'];?></td>
      	<td><?php 
          switch ($row['degree'])
{     case '1': echo "高中 ";
      break;
      case '2': echo  "大学";
      break;
      case '3': echo "本科 ";
      break;
      case '4': echo "研究生";
      break;
        default :
          echo "未选择学历";
          break;




}

        $row['degree'];


        ?></td>

      	<td><img  src="./photos/<?php  echo  $row['pic'];?>" width="80" height="80" alt="头像" title="<?php echo $row['intro'];?>" ></td>
      	<td><a href="admin.php?c=user&m=edituser&uid=<?php echo $row['uid'];?>">修改</a>|<a href="admin.php?c=user&m=deluser&uid=<?php echo $row['uid'];?>">  删除</a></td>
      </tr>
      <?php     
       }
	?>
</table>

</div>

</body>
</html>